/**
 * 
 */
package com.siriusxm.www.mavencore.algo;

/**
 * @author sbaral
 *
 */
public class Multiplication {

	public float multiply(float x, float y) {
		float product = 1;
		String xStr = String.valueOf(x);
		String yStr = String.valueOf(y);
		if(xStr.length() == 1 && yStr.length() == 1) {
			return x * y;
		}
		String newXStr = xStr.substring(0, xStr.length()/2);
		String newYStr = yStr.substring(0, yStr.length()/2);
		int newX = Integer.parseInt(newXStr);
		int newY = Integer.parseInt(newYStr);
		String newXStr2 = xStr.substring(xStr.length()/2 - 1);
		String newYStr2 = yStr.substring(yStr.length()/2 - 1);
		int newX2 = Integer.parseInt(newXStr2);
		int newhY2 = Integer.parseInt(newYStr2);
		return multiply(newX, newY);
	}
	
	public static void main(String[] args) {
		
	}
}
